function bAreValid = AreRawDataValid( aafRawData )
	%
	% load the labels of the raw data events
	tLabels = PeopleCounters.LoadRawEventsLabels();
	%
	aiDoorOpeningTransitions = find( aafRawData(:, 1) == tLabels.DOOR_OPEN );
	aiDoorClosingTransitions = find( aafRawData(:, 1) == tLabels.DOOR_CLOSE );
	% 
	aiLaser1OpeningTransitions = find( aafRawData(:, 1) == tLabels.LASER_1_OPEN );
	aiLaser1ClosingTransitions = find( aafRawData(:, 1) == tLabels.LASER_1_CLOSE );
	% 
	aiLaser2OpeningTransitions = find( aafRawData(:, 1) == tLabels.LASER_2_OPEN );
	aiLaser2ClosingTransitions = find( aafRawData(:, 1) == tLabels.LASER_2_CLOSE );
	%
	% the data are valid if we saw at least 1 transition per type and an
	% equal number of transitions
	bAreValid =																					...
			( numel( aiDoorOpeningTransitions ) > 0 )											...
		&&	( numel( aiLaser1OpeningTransitions ) > 0 )											...
		&&	( numel( aiLaser2OpeningTransitions ) > 0 )											...
		&&	( numel( aiDoorOpeningTransitions )		== numel( aiDoorClosingTransitions ) )		...
		&&	( numel( aiLaser1OpeningTransitions )	== numel( aiLaser1ClosingTransitions ) )	...
		&&	( numel( aiLaser2OpeningTransitions )	== numel( aiLaser2ClosingTransitions ) );
	%
	% DEBUG
% 	if( ~bAreValid )
% 		%
% 		fprintf('event:    door %d / %d   ---   L1 %d / %d   ---   L1 %d / %d\n',	...
% 				numel(aiDoorOpeningTransitions),											...
% 				numel(aiDoorClosingTransitions),											...
% 				numel(aiLaser1OpeningTransitions),											...
% 				numel(aiLaser1ClosingTransitions),											...
% 				numel(aiLaser2OpeningTransitions),											...
% 				numel(aiLaser2ClosingTransitions)											);
% 		%
% 		fprintf('raw data:\n')
% 		disp(aafRawData(:, 1:2));
% 		%
% 	end;%
	%
end % function

